package cn.edu.scau.cmi.wuzhenzhou.composite.consistent;

import java.util.ArrayList;
import java.util.List;

public class ConsistentTeam extends ConsistentOrganization{
	
	
private String name;
	
	public List<ConsistentOrganization> children=new ArrayList<ConsistentOrganization>();


	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}
	
	
	public void addChild(ConsistentOrganization child) {
		this.children.add(child);
	}
	
	public void deleteChild(String name) {
		for(int i=0; i<children.size(); i++) {
			if(children.get(i).getName().equals(name)) {
				children.remove(i);
				return;
			}
		}
	}
	
	public List<ConsistentOrganization> getChildren() {
		return children;
	}
	
}
